/**
 * @Author: 焦质晔
 * @Date: 2019/6/20
 * @Last Modified by:   焦质晔
 * @Last Modified time: 2019-06-20 15:45:00
 */
import axios from '@/api/fetch';
import SERVER from '@/api/server';

// 获取主页面列表数据
export const getList = params => axios.get(`${SERVER.MEMBERS_CLUB}/management/voucher/search`, { params });

// 处理会员卡信息
export const excuteVoucherInit = params => axios.post(`${SERVER.MEMBERS_CLUB}/management/voucher/saveOrUpdate`, params);

// 删除记录
export const doRemove = params => axios.get(`${SERVER.MEMBERS_CLUB}/management/voucher/deleteById`, { params });

// 获取联盟关系
export const getMembershipAlliance = params => axios.get(`${SERVER.MEMBERS_CLUB}/membersAlliance/getMembershipAlliance`);

// 下载代金券
// export const loadVoucher = params => axios.get(`${SERVER.MEMBERS_CLUB}/management/voucher/loadVoucher`);
export const loadVoucher = params => axios.get(`${SERVER.MEMBERS_CLUB}/basic/category/downloadCouponInitialization`, { params });
